<template>
  <div>
    <!-- <div class="open-image" @click="clear" v-if="openImage">
      <img src="@/assets/images/wechat_demo.png" alt="" />
    </div> -->
    <!--头部-->
    <base-info :info="info" ref="baseInfo" />
    <el-row :gutter="16">
      <el-col :span="12">
        <el-card :bordered="false" shadow="never" class="dashboard-console-visit">
          <span slot="header">扫码进入</span>
          <span slot="header" style="margin-left: 30px;">
<!--            <a href="https://shizheng.huianyundun.com/cert/20250625-v1.docx">操作手册下载</a>-->
          </span>
          <div class="qr">
            <img src="../../assets/images/huianyundun.png" alt="" />
            <a href="https://shizheng.huianyundun.com/h5/#/">网页地址：https://shizheng.huianyundun.com/h5/#/</a>
          </div>
        </el-card>
      </el-col>
      <el-col :span="12">
        <el-card :bordered="false" shadow="never" class="dashboard-console-visit">
          <span slot="header">APP下载</span>
          <div class="qr">
            <img src="../../assets/images/app_apk.png" alt="" />
            <a href="javascript:;">使用浏览器扫码下载（不使用微信扫码）</a>
          </div>
        </el-card>
      </el-col>
    </el-row>
  </div>
</template>

<script>
import baseInfo from './components/baseInfo';
import gridMenu from './components/gridMenu';
import visitChart from './components/visitChart';
import userChart from './components/userChart';
import { auth } from '@/api/system';
export default {
  name: 'index',
  components: {
    baseInfo,
    gridMenu,
    visitChart,
    userChart,
  },
  data() {
    return {
      openImage: false,
      visitType: 'day', // day, month, year
      visitDate: [new Date(), new Date()],
      force_reminder: null,
      info:[]
    };
  },
  mounted() {
    this.getAuth();
  },
  methods: {
    getAuth() {
      auth()
        .then((res) => {
          let data = res.data || {};
          this.force_reminder = data.force_reminder;
          if (data.auth_code && data.auth) {
            this.authCode = data.auth_code;
            this.auth = true;
          }
          this.openImage = true;
        })
        .catch((res) => {});
    },
    
    clear() {
      this.openImage = false;
    },
  },
};
</script>

<style lang="scss" scoped>
.qr {
  width: 100%;
  text-align: center;
}
.qr img {
  width: 250px;
  display: block;
  margin: 0 auto 20px;
}
.qr a {
  font-size: 16px;
}
.dashboard-console-visit {
  .ivu-radio-group-button .ivu-radio-wrapper {
    border: none !important;
    box-shadow: none !important;
    padding: 0 12px;
  }
  .ivu-radio-group-button .ivu-radio-wrapper:before,
  .ivu-radio-group-button .ivu-radio-wrapper:after {
    display: none;
  }
}
.open-image {
  transition: none;
  animation: none;
  display: flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  background-color: rgba(0, 0, 0, 0.6);
  height: 100vh;
  width: 100vw;
  top: 0;
  left: 0;
  z-index: 1000;
  img {
    width: 800px;
  }
}
</style>
